﻿using Furion;
using Furion.UnifyResult;
using Furionss.Application;
using Microsoft.AspNetCore.Builder;
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.DependencyInjection;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Furionss.Web.Core
{
    [AppStartup(800)]
    public sealed class FurWebCoreStartUp : AppStartup
    {
        public void ConfigureServices(IServiceCollection services)
        {
            //添加规范化文档服务
            //services.AddSpecificationDocuments();

            //添加动态接口控制器服务
            services.AddControllers().AddDynamicApiControllers();

            //添加选项配置
            services.AddConfigurableOptions<AppInfoOptions>();


        }

        public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
        {
            //添加规范化文档中间件
            //app.UseSpecificationDocuments();


            //app.UseEndpoints(endpoints =>
            //{
            //    endpoints.MapControllers();
            //});
        }

    }
}
